<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ page session="false" contentType="text/html; charset=UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title></title>
<jsp:include page="/WEB-INF/views/common/header.jsp" />

<link rel="stylesheet" href="<c:out value="${pageContext.request.contextPath}"/>/resources/common/bootstrap/css/bootstrap-datepicker.min.css">

<script type="text/javascript" src="<c:out value="${pageContext.request.contextPath}"/>/resources/js/repair_create_popup.js"></script>
<script type="text/javascript" src="<c:out value="${pageContext.request.contextPath}"/>/resources/common/bootstrap/js/bootstrap-datepicker.min.js"></script>

<script type="text/javascript">
	$(document).ready(function() {
		var firstdate;
		
		var startdate = $('#release_start_date').datepicker({
			format: "yyyy-mm-dd",
			autoclose: true,
			todayHighlight: true
		}).on('changeDate', function(ev) {
			firstdate = ev.date.valueOf();
		});
		
		$('#release_end_date').datepicker({
			format: "yyyy-mm-dd",
			autoclose: true,
			todayHighlight: true,
		});
	});
	
</script>

</head>
<body>
	<jsp:include page="/WEB-INF/views/main/menu.jsp" />

	<div class="container">
		<div class="page-header">
			<h3>고객수리완료내역서</h3>
		</div>
		<form class="form-inline">
			<h4>조회조건</h4>
			<div class="row">
				<div class="col-sm-6">
					<div class="form-group form-group-sm">
						<label class="control-label" for="customer_code" style="width: 100px">고객</label> 
						<input type="text" class="form-control" id="customer_code" placeholder="고객 코드" disabled>
						<div class="input-group">
							<label class="sr-only" for="customer_name">고객명</label> 
							<input type="text" class="form-control" id="customer_name" placeholder="고객 명" disabled> 
							<span class="input-group-btn">
								<input type="button" class="btn btn-primary btn-sm" id="customer_btn" value="선택"/>
							</span>
						</div>
					</div>
				</div>
				<div class="col-sm-6">
					<div class="form-group form-group-sm">
						<label class="control-label" for="release_date" style="width: 100px">출고일자</label> 
						<div class="input-group date" id="release_start_date">
  							<input type="text" class="form-control" size="7" disabled="disabled">
  								<span class="input-group-addon"><i class="glyphicon glyphicon-calendar"></i></span>
						</div>
						<label class="control-label" for="release_date" style="width: 90px; text-align:center;">~</label> 
						<div class="input-group date" id="release_end_date">
  							<input type="text" class="form-control" size="7" disabled="disabled">
  								<span class="input-group-addon"><i class="glyphicon glyphicon-calendar"></i></span>
						</div>
					</div>
				</div>
			</div>
			<p />
			<div class="row">
				<div class="col-sm-6">
					<div class="form-group form-group-sm">
						<label class="control-label" for="operator_code" style="width: 100px">운용국</label> 
						<input type="text" class="form-control" id="operator_code" placeholder="운용국 코드" disabled>
						<div class="input-group">
							<label class="sr-only" for="operator_name">운용국 명</label> 
							<input type="text" class="form-control" id="operator_name" placeholder="운용국 명" disabled> 
							<span class="input-group-btn">
								<input type="button" class="btn btn-primary btn-sm" id="operator_btn" value="선택"/>
							</span>
						</div>
					</div>
				</div>
				<div class="col-sm-6">
					<div class="form-group form-group-sm">
						<label class="control-label" for="receipt_dept" style="width: 100px">접수부서</label> 
						<input type="text" class="form-control" id="receipt_dept_code" placeholder="부서코드" disabled>
						<div class="input-group">
							<input type="text" class="form-control" id="receipt_dept_name" placeholder="접수 부서명" disabled> 
							<span class="input-group-btn"> 
								<input type="button" class="btn btn-primary btn-sm" id="receipt_dept_btn" value="선택" />
							</span>
						</div>
					</div>
				</div>
			</div>
			<p />
			<div class="row">
				<div class="col-sm-6">
					<div class="form-group form-group-sm">
						<label class="control-label" for="model" style="width: 100px">기종</label> 
						<input type="text" class="form-control" id="model_code" placeholder="기종 코드" disabled>
						<div class="input-group">
							<input type="text" class="form-control" id="model_name" placeholder="기종 명" disabled> 
							<span class="input-group-btn"> 
								<input type="button" class="btn btn-primary btn-sm" id="model_name_btn" value="선택" />
							</span>
						</div>
					</div>
				</div>
				<div class="col-sm-6">
					<div class="form-group form-group-sm">
						<label class="control-label" for="customer_claim_check" style="width: 100px">고객청구 여부</label>
						<select class="form-control input-lg" style="width: 350px;" id="customer_claim_check">
							<option>고객청구</option>
						</select> 
					</div>
				</div>
			</div>
			<p />
			<hr />
			<h4>완료내역</h4>
		<p />
		<table data-toggle="table"
			<%-- data-url="<c:out value="${pageContext.request.contextPath}"/>/resources/test_data/data.json" --%>
			data-height="600" data-pagination="true" data-search="false">
			<thead>
				<tr>
					<th data-field="state" data-checkbox="true"></th>
					<th data-field="model_code" data-align="center">기종코드</th>
					<th data-field="model_name" data-align="center">기종명</th>
					<th data-field="item_code" data-align="center">품목코드</th>
					<th data-field="item_name" data-align="center">품명</th>
					<th data-field="serial_no" data-align="center">Serial No.</th>
					<th data-field="commission_code" data-align="center">의뢰번호</th>
					<th data-field="commission_date" data-align="center">의뢰일</th>
					<th data-field="repair_component_code" data-align="center">수리부품코드</th>
					<th data-field="repair_component_name" data-align="center">수리부품명</th>
					<th data-field="repair_component_location" data-align="center">수리부품위치</th>
					<th data-field="repair_component_amount" data-align="center">수량</th>
					<th data-field="repair_context" data-align="center">수리내용</th>
					<th data-field="parcel_service_check" data-align="center">택배유무</th>
				</tr>
			</thead>
		</table>
		<p />
		<div class="row">
			<div class="col-sm-3">
				<div class="form-group form-group-sm">
					<label class="control-label" for="amount" style="width: 100px">수량</label> 
					<input type="text" class="form-control" id="amount" size="21">
				</div>
			</div>
			<div class="col-sm-offset-5 col-sm-2">
				<a href=""><input type="button"
					class="btn btn-primary btn-sm btn-block" id="statement_total_print_btn" value="완료내역서발행(전체)"></a>
			</div>
			<div class="col-sm-2">
				<a href=""><input type="button"
					class="btn btn-primary btn-sm btn-block" id="statement_check_print_btn" value="완료내역서발행(체크)"></a>
			</div>
		</div>
		</form>
	</div>
	<div class="modal fade" role="dialog" id="modalDiv">
		<div class="modal-dialog">
			<div class="modal-content"></div>
		</div>
	</div>
</body>
</html>